cmake_minimum_required(VERSION 2.8)
PROJECT( curl )
SET(CMAKE_CXX_COMPILER "clang++") 
SET(CMAKE_CXX_FLAGS "-Wall -W")
SET( DIR_OUTPUT output )
FILE(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/${DIR_OUTPUT})
SET( BIN_NAME ${DIR_OUTPUT}/test )
INCLUDE_DIRECTORIES( include )

FIND_LIBRARY( CURL curl )
FIND_LIBRARY( BOOSTSYSTEM boost_system-mt )
FIND_LIBRARY( BOOSTTHREAD boost_thread-mt )
FIND_LIBRARY( LOG4CPP log4cpp )
FIND_LIBRARY( SSL ssl )

AUX_SOURCE_DIRECTORY( src DIR_SRCS )
ADD_EXECUTABLE( ${BIN_NAME} ${DIR_SRCS} )
TARGET_LINK_LIBRARIES( ${BIN_NAME}  ${CURL} ${BOOSTSYSTEM} ${BOOSTTHREAD} ${LOG4CPP} ${SSL} )
